package com.heima.wemedia.controller.v1;


import com.heima.model.common.dtos.ResponseResult;
import com.heima.model.wemedia.dtos.WmFollowFanceDTO;
import com.heima.model.wemedia.vos.WmFansImageVo;
import com.heima.model.wemedia.vos.WmFansListVO;
import com.heima.wemedia.service.WmFansService;
import io.swagger.annotations.Api;
import org.springframework.beans.factory.annotation.Autowired;
import org.springframework.web.bind.annotation.*;

import java.util.List;
@Api("粉丝图表")
@RestController
@RequestMapping("api/v1/user_fans")
public class InfoController {
    @Autowired
    WmFansService wmFansService;
    @GetMapping("/fans_portrait")
    public ResponseResult<List<WmFansImageVo>> Info(){
        return wmFansService.getFansImageDate();
    }

    @PostMapping("/list")
    public ResponseResult<List<WmFansListVO>>List(){
        return wmFansService.getList();
    }
    @PostMapping("/change_follow_state")
    public ResponseResult change_follow_state(@RequestBody WmFollowFanceDTO dto){
        return wmFansService.change_follow_state(dto);
    }


}
